package com.cloud.common.feign;

import com.cloud.common.entity.ShopOrder;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @author 李均华
 * @date 2021/6/4
 * @desc
 */
@FeignClient(name = "shop-order")
public interface OrderService {

    /**
     * 用户下单
     * @param id 商品id
     * @param num 下单数量
     * @return 订单
     */
    @GetMapping("/shop/order/order/{id}/{num}")
    ShopOrder order(@PathVariable("id") Integer id, @PathVariable("num") Integer num);

}
